﻿<Window x:Class="IGL_Talk_Windows_Desktop.View.LoginView"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        xmlns:ap="clr-namespace:IGL_Talk_Windows_Desktop.AttachedProperties"
        ap:DialogCloser.DialogResult="{Binding CloseLoginView}"
        Title="LoginView" SizeToContent="WidthAndHeight"
        WindowStartupLocation="CenterScreen" AllowsTransparency="True" WindowStyle="None"
        Background="Transparent">
    <Border CornerRadius="2" Background="{DynamicResource BlueGradient}" MouseLeftButtonDown="Border_MouseLeftButtonDown">
        <Grid>
            <Grid.RowDefinitions>
                <RowDefinition Height="Auto"/>
                <RowDefinition Height="*"/>
            </Grid.RowDefinitions>
            <StackPanel Grid.Row="0" Width="30" HorizontalAlignment="Right">
                <Button Command="{Binding CloseWindowCommand}" Style="{DynamicResource CloseButton}" FontSize="14" Content="x"/>
            </StackPanel>
            <StackPanel Grid.Row="1" VerticalAlignment="Center"  Margin="60,0">
                <StackPanel  Orientation="Horizontal" Margin="0,10">
                    <Image Width="100" Source="..\logo.png"/>                    
                    <Label Content="IGLTalk" Margin="20,0,0,0" VerticalAlignment="Bottom" FontSize="28" Foreground="White" />
                </StackPanel>

                <TextBox Text="{Binding UserName, UpdateSourceTrigger=PropertyChanged}" Height="30" Width="220" VerticalContentAlignment="Center" >
                    <TextBox.InputBindings>
                        <KeyBinding Key="Enter" Command="{Binding LoginCommand}"/>
                    </TextBox.InputBindings>
                </TextBox>
                <Button Content="Login"  Command="{Binding LoginCommand}"  Height="30" Width="80" Margin="0,20" HorizontalAlignment="Right" />
            </StackPanel>
        </Grid>
    </Border>
</Window>
